/**
 * 
 */
package com.onstar.cn.map.listener;

import com.amap.api.maps2d.AMap.OnMapLongClickListener;
import com.amap.api.maps2d.model.LatLng;
import com.onstar.cn.map.core.impl.OGeoPointImpl;

/**
 * @author Qiying Gong
 *
 * @Created 2013-9-26
 */
public class AMapLongPressHandler implements OnMapLongClickListener{

	private OMapLongPressListener longPressListener;
	
	public AMapLongPressHandler(OMapLongPressListener listener){
		this.longPressListener = listener;
	}
	@Override
	public void onMapLongClick(LatLng point) {
		OGeoPointImpl pt = new OGeoPointImpl(point.latitude, point.longitude);
		if (this.longPressListener != null) {
			this.longPressListener.OnMapLongPress(pt);
		}
	}

}
